#pragma GCC optimize(2)
#include<bits/stdc++.h>

using namespace std;

typedef long long ll;
#define pi acos(-1.0)
#define e exp(1.0)
ll T,N,A,B;  
int main()
{
//  freopen(".../.txt","w",stdout);
	ios::sync_with_stdio(false);
	cin>>T;
	while(T--){
		cin>>N>>A>>B;
		ll d=__gcd(A,B);
		ll ans=N/d;
		if(ans&1)
		puts("Yes");
		else
		puts("No");
	}
	return 0;
}
